package console

import (
	"github.com/astaxie/beego"
	"github.com/mojocn/base64Captcha"
)

type RegController struct {
	beego.Controller
}

func (this *RegController) Get()  {
	var configD = base64Captcha.ConfigDigit{
		Height:     80,
		Width:      240,
		MaxSkew:    0.7,
		DotCount:   80,
		CaptchaLen: 5,
	}
	idKeyD, capD := base64Captcha.GenerateCaptcha("", configD)
	//以base64编码
	base64stringD := base64Captcha.CaptchaWriteToBase64Encoding(capD)
	this.Data["idKey"] = idKeyD
	this.Data["base64stringD"] = base64stringD
	this.TplName = "console/reg/reg.tpl"
}

func (this *RegController) Post() {

}